package logic.characters;

import logic.enemies.Enemy;
import logic.pruebas.GamePanel;
import logic.threads.ShootBlueWolf;
import logic.threads.ShootBullet;

/**
 * @author Unai
 * Dispara un proyectil que atraviesa enemigos
 *
 */
public class Zabuza extends Player{
	private static final long serialVersionUID = -8276584364260237887L;

	public Zabuza(int x, int y, GamePanel panel, String nomImg, int salud, int attack, int defense, int magic, int resistance, int speed, int jump, int stamina, int[] abilitiesIDs ) {
		super(x, y, panel, nomImg, salud, attack, defense, magic, resistance, speed, jump, stamina, abilitiesIDs);
		specialCost = 5;
		shootCost = 2;
		staminaRecovery = 2;
		lifeRecovery = 1;
		widthDifference = 50;
		heightDifference = 50;
		collisionWidth = 30;
		collisionHeight = altura - heightDifference;
		attackTime = 900;
		specialTime = 400;
	}

	@Override
	public void shoot() {
		Runnable shootBullet = new ShootBullet(collisionX, collisionY, panelJuego, lookingRight, enemies, blocks, magic, true, this, shootTime);
		Thread fThread = new Thread(shootBullet);
		fThread.start();
	}

	@Override
	public void specialEffect(Enemy enemy) {
		damage(enemy.attack);
	}

	public void special() {
		super.special();
		Runnable shootBlueWolf = new ShootBlueWolf(collisionX, collisionY, panelJuego, lookingRight, enemies, blocks, magic, true, this);
		Thread fThread = new Thread(shootBlueWolf);
		fThread.start();
	}
}
